#ifndef _UI_EVENT_BI_
#define _UI_EVENT_BI_ -1

namespace ui

enum GEVENT explicit 'unless noted return 1 if event is handled by you or your children
	mousemove
	mousedown
	leftclick
	rightclick
	middleclick
	wheel
	keystroke
	time_e
	repaint 'always return 0
	resize 'always return 0
	destroy 'issued when the window is attempting to close, return 1 to accept or 0 to cancel
	user
end enum

type _GUI_EVENT_
	id as GEVENT
	union
		type 'mouse location
			m_x as integer
			m_y as integer
			union
				button as integer
				wheel as integer
			end union
		end type
		type
			ascii as integer
			scancode as integer
		End Type
		t_e as double
		user as any ptr
	end union
end type

end namespace

#endif
